package com.chinacoal.microservice.fallback;

import com.chinacoal.microservice.DeviceManagementClient;
import com.chinacoal.microservice.pojo.CcmsSmartleasingDeviceManagement;
import com.chinacoal.microservice.util.CodeMsg;
import com.chinacoal.microservice.util.QueryCriteria;
import com.chinacoal.microservice.util.Result;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @author zhuliang
 * @version V1.0
 * @Description: 运维管理-设备管理-异常回退类
 * @date 2020-12-17 10：52
 */
@Component
public class DeviceManagementClientFallback implements DeviceManagementClient {

    /**
     * @Description: 查询所有的设备信息（带分页）
     * @author zhuliang
     * @date 2020/12/17 11:20
     */
    @Override
    public Result<List<CcmsSmartleasingDeviceManagement>> getAllByPage(QueryCriteria queryCriteria, String token) {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 条件查询所有的设备信息（带分页）
     * @author zhuliang
     * @date 2020/12/17 11:20
     */
    @Override
    public Result<List<CcmsSmartleasingDeviceManagement>> getAllByCondition(QueryCriteria queryCriteria, String token) {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 根据设备id查询设备信息
     * @author zhuliang
     * @date 2020/12/17 14:28
     */
    @Override
    public Result<CcmsSmartleasingDeviceManagement> getDeviceById(String pkDeviceManagementId, String token) {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 修改设备信息
     * @author zhuliang
     * @date 2020/12/17 14:28
     */
    @Override
    public Result updateByDevice(CcmsSmartleasingDeviceManagement deviceManagement, String token) {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 添加设备信息
     * @author zhuliang
     * @date 2020/12/17 14:28
     */
    @Override
    public Result addByDevice(CcmsSmartleasingDeviceManagement deviceManagement, String token) {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 获取云丁的token的路径信息
     * @author zhuliang
     * @date 2021/2/1 16:07
     */
    @Override
    public Result getYunDingTokenUrl() {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 获取微羽的token的路径信息
     * @author zhuliang
     * @date 2021/2/1 16:07
     */
    @Override
    public Result getWeiYuTokenUrl() {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 获取绿米的token的路径信息
     * @author zhuliang
     * @date 2021/2/1 16:07
     */
    @Override
    public Result getLuMiTokenUrl(String code) {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }

    /**
     * @Description: 存放第三方设备token信息
     * @author zhuliang
     * @date 2021/2/1 16:50
     */
    @Override
    public Result getThirdPartyToken(String yunDingToken, String weiYuToken, String luMiAccessToken, String luMiRefreshToken) {
        return Result.error(CodeMsg.METHOD_NOT_SUPPORTED);
    }
}
